import { useDict } from '@/utils/dict/useDict'
let course_type = useDict('course_type')

export const searchList = [
  {
    type: 'input',
    name: '奖项名称',
    field: 'awardName',
  },
]

export const listColumns = [
  {
    title: '奖项名称',
    key: 'awardName',
  },
  {
    title: '颁奖单位',
    key: 'awardingUnit',
  },
  {
    title: '奖项级别',
    key: 'awardLevelName',
  },
  {
    title: '获奖等级',
    key: 'awardRankName',
  },
  {
    title: '成果类型',
    key: 'resultTypeName',
  },
  {
    title: '所属学院',
    key: 'collageName',
  },
  {
    title: '获奖人',
    key: 'winner',
  },
  {
    title: '获奖时间',
    key: 'awardDate',
  }
]

export const actionArr = [
  {
    action: 'look',
    value: '查看',
  },
  {
    action: 'edit',
    value: '编辑',
  },
  {
    action: 'del',
    value: '删除',
  }
]
export const btnList = [
  {
    action: 'add',
    value: '新增',
    auth: ''
  }
];

export const rules = {
  awardName: [
    { required: true, message: '请输入课程名称', trigger: 'change' },
  ],
  awardingUnit: [
    { required: true, message: '请输入颁奖单位', trigger: 'change' },
  ],
  winner: [
    { required: true, message: '请输入获奖人', trigger: 'change' },
  ],
  awardLevelId: [
    { required: true, message: '请选择奖项级别', trigger: 'change' },
  ],
  awardRankId: [
    { required: true, message: '请选择获奖等级', trigger: 'change' },
  ],
  resultTypeId: [
    { required: true, message: '请选择成果类型', trigger: 'change' },
  ],
  awardDate: [
    { required: true, message: '请选择获奖时间', trigger: 'change' },
  ],
  resultIntro: [
    { required: true, message: '请输入成果介绍', trigger: 'change' },
  ],
  certificateFileId: [
    { required: true, message: '请上传证书附件', trigger: 'change' },
  ],
}